<div class="panel border-primary no-border border-3-top topcss" data-panel-control>
    <div class="panel-heading">
        <div class="panel-title">
            <h5>&nbsp;&nbsp;&nbsp;营销概览</h5>
        </div>
    </div>
    <div class="panel-body">
        <ql-menu [model]="index" (modelChange)="handle($event)" class="ql-menu-demo" mode="horizontal">
            <ql-menu-item index="1">营销活动分布</ql-menu-item>
            <ql-menu-item index="2">客户经理业绩完成率</ql-menu-item>
        </ql-menu>

        <div class="p-15" heading="营销活动分布" *ngIf="tabIndex=='1'">
            <div class="panel-body">
                <div>
                    <label class="ql-input-group__prepend fontfour">业务条线</label>
                    <select name="riskLevel" class="ywxtcss">
            <option value="0" selected>财富管理</option>
            <option value="1" >私人银行</option>
          </select>
                    <button type="button" (click)="oneHandle(1)" class="btn btn-primary btn-sm fontfour margeft">查询</button>
                </div>
                <div *ngIf="oneIndex==1">
                    <div echarts [options]="barchartOption[0]" [merge]="barchartOption[1]" [ngStyle]="{height: hdata6 == 'NaNpx' ? '400px' : hdata6}" [loading]="loading"></div>
                </div>
                <div *ngIf="oneIndex==2">
                    <table class="table table-striped table-bordered table-hover">
                        <thead class="ql-text-center fontfour">
                            <tr>
                                <th scope="col">活动名称</th>
                                <th scope="col">客户数</th>
                                <th scope="col">完成率</th>
                                <th scope="col">AUM</th>
                                <th scope="col">开始时间</th>
                                <th scope="col">结束时间</th>
                                <!--<th scope="col">年累计资产变动</th>-->
                            </tr>
                        </thead>
                        <tbody>
                            <tr *ngFor="let data of res; let i = index" class="ql-text-center fontthree">
                                <td>{{data.targetName}}</td>
                                <td style="text-align: center;">{{data.count}}</td>
                                <td style="text-align: right;">{{data.amount}}</td>
                                <td style="text-align: right;">{{data.aum}}</td>
                                <td>{{data.familyAUM}}</td>
                                <td>{{data.dayChangeAmount}}</td>
                                <!--<td>{{data.yearChangeAmount}}</td>-->
                            </tr>
                        </tbody>
                        <tfoot>
                            <tr>
                                <td colspan="7">
                                    <button type="button" (click)="oneHandle(1)" class="btn btn-primary btn-sm ql-text-right fontfour">数据图形</button>
                                    <button type="button" class="btn btn-primary btn-sm ql-text-right fontfour margeri">更多</button>
                                </td>
                            </tr>
                        </tfoot>
                    </table>
                </div>
            </div>
        </div>

        <div class="p-15" heading="客户标签使用程度" *ngIf="tabIndex=='2'">
            <div class="panel-body">
                <div *ngIf="twoIndex==1" echarts [options]="labelOption[0]" [merge]="labelOption[1]" [ngStyle]="{height: hdata6 == 'NaNpx' ? '400px' : hdata6}" [loading]="loading"></div>
                <div *ngIf="twoIndex==2">
                    <table class="table table-striped table-bordered table-hover">
                        <thead class="ql-text-center fontfour">
                            <tr>
                                <th scope="col"></th>
                                <th *ngFor="let data of labelres; let i = index" scope="col">{{data.dataDate}}</th>
                                <!--<th scope="col">年累计资产变动</th>-->
                            </tr>
                        </thead>
                        <tbody>
                            <tr class="ql-text-right fontthree">
                                <td class="ql-text-center">业绩完成率</td>
                                <td *ngFor="let data of labelres; let i = index">{{data.amount}}%</td>
                            </tr>
                            <tr class="ql-text-right fontthree">
                                <td class="ql-text-center">杨树</td>
                                <td *ngFor="let data of labelres; let i = index">{{data.yang}}元</td>
                            </tr>
                            <tr class="ql-text-right fontthree">
                                <td class="ql-text-center">王星</td>
                                <td *ngFor="let data of labelres; let i = index">{{data.wang}}元</td>
                            </tr>
                            <tr class="ql-text-right fontthree">
                                <td class="ql-text-center">李燕</td>
                                <td *ngFor="let data of labelres; let i = index">{{data.li}}元</td>
                            </tr>
                        </tbody>
                        <tfoot>
                            <tr>
                                <td colspan="7">
                                    <button type="button" (click)="twoHandle(1)" class="btn btn-primary btn-sm  ql-text-right fontfour">数据图形</button>
                                    <button type="button" class="btn btn-primary btn-sm  ql-text-right fontfour margeri">更多</button>
                                </td>
                            </tr>

                        </tfoot>
                    </table>
                </div>
            </div>
        </div>
    </div>
</div>
